package BasicClient;

import java.io.IOException;
import java.net.UnknownHostException;
import java.util.logging.Level;
import java.util.logging.Logger;

public class EntryPoint {	

	public static void main(String[] args) {
		Logger log = Logger.getLogger("cLogger");
		
		
		System.out.println("----------------------");
		log.entering("entryPoint", "main");
//		log.fine("you probably won't even have your logger set to output this level");
		log.log( Level.INFO, "TEST MESSAGE---");
		log.info("this is some information");
		log.warning("this is a more serious warning, pay attention");
		log.severe("holy potatoes, Batman! Something really *really* bad happened!");		
		System.out.println("!!!!!!!!!!!!!!!!!!!!");
		
		
		// these shouldnt be harded, obviously!
		String addr = "localhost";
		int port = 6550;
		
		
		AbstractClient c = new ClientImpl();		
		Server serv = null;
		try {
			serv = new ServerImpl(addr,port,c);			
		} catch (UnknownHostException e) {
			e.printStackTrace();
		} catch (IOException e) {
			e.printStackTrace();
		}		
		c.setServer(serv);
		
		
		
		c.requestPlayerId();
		System.out.println("Client program finished executing; Exiting now");
		
	}	
}
